﻿//--------------------------------------------------------------------------
// 
//  Copyright (c) Chili Software.  All rights reserved. 
// 
//  File: IRelatedPropertiesPairCollection.cs
//
//  Description: Holds a list related properties pairs.
// 
//--------------------------------------------------------------------------

using System;
using System.Collections.Generic;

namespace Chili.Opf3.Mapping
{
	/// <summary>
	/// This interface contains a list of <see cref="IRelatedPropertiesPair">IRelatedPropertiesPair</see> interfaces.
	/// </summary>
	public interface IRelatedPropertiesPairCollection : IEnumerable<IRelatedPropertiesPair>
	{
		/// <summary>
		/// Determines whether an element is in the collection.
		/// </summary>
		/// <param name="item">The object to locate in the collection.</param>
		/// <returns>True if item is found in the collection; otherwise, false.</returns>
		bool Contains(IRelatedPropertiesPair item);

		/// <summary>
		/// Copies the entire collection to a compatible one-dimensional array, starting at the specified index of the target array.
		/// </summary>
		/// <param name="array">The one-dimensional System.Array that is the destination of the elements copied from collection. The System.Array must have zero-based indexing.</param>
		/// <param name="arrayIndex">The zero-based index in array at which copying begins.</param>
		void CopyTo(IRelatedPropertiesPair[] array, int arrayIndex);

		/// <summary>
		/// Gets the number of elements actually contained in the collection.
		/// </summary>
		int Count { get; }

		/// <summary>
		/// Returns whether the collection is read-only.
		/// </summary>
		bool IsReadOnly { get; }

		/// <summary>
		/// Returns the item at the given index.
		/// </summary>
		/// <param name="index">The index of the item that is returned.</param>
		/// <returns>The item at the given index.</returns>
		IRelatedPropertiesPair this[int index] { get; }
	}
}
